package tongwentongshu.com.app.contract;

import android.app.Activity;
import android.content.Intent;
import android.graphics.Bitmap;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.widget.EditText;

import com.amap.api.services.core.LatLonPoint;
import com.amap.api.services.core.PoiItem;

import java.util.List;
import java.util.Map;

import tongwentongshu.com.app.bean.BookTypeBean;
import tongwentongshu.com.app.bean.RqcordBook;
import tongwentongshu.com.app.bean.ShareBean;

/**
 * Created by XiongBin on 2017/6/27.
 */

public interface ShareBookContract {
    //初次用不想那么麻烦所以把M层当做P层用，处理拍照相关
    interface Model {

        void getFileByPhotoAlbum(Activity act);//相机调用

        void getFileByPhotograph(Activity act);//相册调用

        void onActivityResult(int requestCode, int resultCode,
                              Intent data);//相册调用

        void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions,
                                        @NonNull int[] grantResults);

    }

    interface View {
        void shareOnSuccess(ShareBean bean);

        void setBookImage(Bitmap bitmap, String url);

        void setPoiItem(PoiItem p);

        void setLocation(String location_string);

        void setCodeData(RqcordBook b);

        void setBookType(BookTypeBean msg);

        Bitmap getImg();
    }

    interface Presenter {


        void share();

        void setPricePoint(EditText editText);

        void getAddress(Activity act);

        List<PoiItem> getPoiList();

        void getBookType();

        Map<String, String> getStreet();

        Map<String, String> getTradingarea();

        void Submit(Map<String, String> map, String url1, String url2);
    }
}
